<?php
namespace app\api\controller;

use app\BaseController;

class Index extends BaseController
{
    public function index()
    {
        return json([
            'code' => 20000,
            'message' => 'OK',
            'data' => [
                'id' => 1,
                'username' => 'kakarotto'
            ]
        ]);
    }

    public function hello($name = 'ThinkPHP6')
    {
        return 'hello,' . $name;
    }
}
